package com;

public class student {
//    学号
    private int id;
//    姓名
    private String name;
//    年龄
    private int age;
//    性别
    private String sex;


//    fn+alt+insert，提供无参和有参的构造
    public student() {
    }

    public student(int id, String name, int age, String sex) {
        this.id = id;
        this.name = name;
        this.age = age;
        this.sex = sex;
    }

//    fn+alt+insert，提供get和set方法
//    get是获得的意思，set是设置的意思

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getAge() {
        return age;
    }

    public void setAge(int age) {
        this.age = age;
    }

    public String getSex() {
        return sex;
    }

    public void setSex(String sex) {
        this.sex = sex;
    }
}

